package com.crr.demo.common;

import com.crr.demo.utils.DateUtils;
import com.fasterxml.jackson.annotation.JsonInclude;


public class ResultModel {
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private  Object data;
    private int errCode;
    private String timestamp = DateUtils.getTime();

    public ResultModel() {
    }

    public ResultModel(int errCode) {
        this.errCode = errCode;
    }

    public ResultModel(String timestamp) {
        this.timestamp = timestamp;
    }

    public ResultModel(Object data) {
        this.data = data;
    }

    public ResultModel(int errCode, Object data) {
        this.errCode = errCode;
        this.data = data;
    }

    public ResultModel(int errCode, String timestamp) {
        this.errCode = errCode;
        this.timestamp = timestamp;
    }

    public ResultModel(String timestamp, Object data) {
        this.timestamp = timestamp;
        this.data = data;
    }

    public ResultModel(int errCode, String timestamp, Object data) {
        this.errCode = errCode;
        this.timestamp = timestamp;
        this.data = data;
    }
       public ResultModel( Object data,int errCode, String timestamp) {
        this.errCode = errCode;
        this.timestamp = timestamp;
        this.data = data;
    }

    public int getErrCode() {
        return errCode;
    }

    public void setErrCode(int errCode) {
        this.errCode = errCode;
    }

    public String getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(String timestamp) {
        this.timestamp = timestamp;
    }

    public Object getData() {
        return data;
    }

    public void setData(Object data) {
        this.data = data;
    }
}
